using System;
using System.Collections.Generic;
using System.IO;
using System.Text;

namespace ConsoleApplication1
{
    class Program
    {
        static void Main(string[] args)
        {
            Dictionary<string, object> dict = new Dictionary<string, object>();
            using (System.IO.StreamReader sr = new StreamReader("wordlist.dic", Encoding.Default))
            {
                string s;
                while ((s = sr.ReadLine()) != null)
                {
                    dict[s] = null;
                }
            }
            System.IO.StreamWriter sw = new StreamWriter("wordlist.dic", true, Encoding.Default);
            using (System.IO.StreamReader sr = new StreamReader("wordlist.txt", Encoding.Default))
            {
                string s;
                while ((s = sr.ReadLine()) != null)
                {
                    if(s.Length>0 && !dict.ContainsKey(s))
                    {
                        sw.WriteLine(s);
                    }
                }
            }
            sw.Close();
        }
    }
}
